let statusBarHeight = getApp().globalData.navHeight;
Page({
    data: {
        statusBarHeight: statusBarHeight,
        title: '',
        titleList: ['规则频道','最新动态','新手入门'],
        listData: [],
        listData1: [
            {
                title: '轮到你播违禁类目规则',
                type: 'a1'
            },{
                title: '轮到你播直播平台公约',
                type: 'a2'
            },{
                title: '轮到你播直播平台管理规范',
                type: 'a3'
            },{
                title: '轮到你播直播平台违规管理办法',
                type: 'a4'
            },{
                title: '平台商家售后服务规则',
                type: 'a5'
            },
        ],
        listData2: [
            {
                title: '5G风口，轮到你播势不可挡',
                type: 'b1'
            },{
                title: '5G微信直播的赛道在哪里',
                type: 'b2'
            }
        ],
        listData3: [
            {
                title: '平台直播八个技巧',
                type: 'c1'
            },{
                title: '新手上路快速玩转轮到你播',
                type: 'c2'
            },{
                title: '新手主播初始阶段如何获得直播间流量',
                type: 'c3'
            },{
                title: '直播前准备',
                type: 'c4'
            },{
                title: '直播相关问题FAQ',
                type: 'c5'
            }
        ],
    },
    onLoad: function (options) {
        const arr = options.type === '1' ? this.data.listData1 : options.type === '2' ? this.data.listData2 : this.data.listData3
        this.setData({
            title: this.data.titleList[+options.type-1],
            listData: arr
        })
    },
    onShow: function () {

    },
    tocontent(e) {
        wx.navigateTo({
            url: `/pages/busSchoolDetial/index?type=${e.currentTarget.dataset.type}`,
          })
    }
})